<%@ page contentType="text/html;charset=utf-8" %>
<%@ page import="ut.data.User" %>
<%
	User user = (User)session.getAttribute("user");
	if(user == null){
		response.sendRedirect("/");
		return;
	}
	if(user.verify == 2){
		response.sendRedirect("/account/user-info.jsp");
		return;
	}
%>
<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<title>UT終極一翻！ | 驗證手機</title>
	<link rel="stylesheet" type="text/css" href="/style.css" media="all" />
	<script type="text/javascript" src="/js/Utility.js"></script>
	<script type="text/javascript" src="/js/Message.js"></script>
	<script type="text/javascript" src="/js/Ajax.js"></script>
	<script type="text/javascript" src="/js/Button.js"></script>
	<script type="text/javascript" src="/js/Account.js"></script>
	<script type="text/javascript" src="/script.js"></script>
</head>
<body onload="init();">
<%@ include file="/include/banner.jsp" %>
	<div class="content">
		<div class="title">驗證手機</div>
<%
	if(user.phone == "0"){
%>
		<div class="block-center">
			很抱歉，您已驗證手機失敗超過三次。<br/>
			請直接聯絡客服以完成此項驗證。
		</div>
<%
	}else{
%>
		<form class="block-center" method="post" onsubmit="Account.verifyPhone(this, 'step2');return false;">
			<div id="step1">
				請輸入欲收取驗證碼的手機號碼：<input type="text" name="phone" class="center" /><br/>
				<span class="mark-gray comment">（僅接受台灣地區手機用戶，例：0953145687。簡訊費用由本站負擔。）</span><br/>
				<span class="mark-gray comment">（若驗證失敗超過三次，本站將不再接受您的手機驗證請求，請謹慎處理。）</span><br/>
				<span class="mark-gray comment">（成功驗證手機後，可讓他人更信任您，增加接案或發案成功的機會。）</span><br/>
			</div>
			<br/>
			<div id="step2" style="display:none">
				請輸入簡訊驗證碼：<input type="text" name="code" class="center" /><br/>
				<span class="mark-gray comment">（驗證碼需在一小時內輸入，否則失效。）</span>
			</div>
			<input type="hidden" name="step" value="1" />
			<input class="button" style="margin-top:30px" type="submit"	value="開始驗證"
				onmousedown="this.style.borderStyle='inset'"
				onmouseup="this.style.borderStyle='outset'"
				onmouseout="this.style.borderStyle='outset'" />
		</form>
<%
	}
%>
<%@ include file="/include/foot.jsp" %>
	</div>
</body>
</html>